home *** CD-ROM | disk | FTP | other *** search
/ QRZ! Ham Radio 6 / QRZ Ham Radio Callsign Database - Volume 6.iso / pc / files / mac / varilogs.hqx / Logs / Logging Stacks USA / Contester / background_2737.txt < prev    next >
Encoding:
Text File  |  1987-11-25  |  12.3 KB  |  540 lines

  1. -- background: 2737 from stack: in
  2. -- bmap block id: 3261
  3. -- flags: 0000
  4. -- background id: 0
  5. -- name: QSO
  6. ----- HyperTalk script -----
  7. on closeField
  8.   get chartonum of field "precedence" -- checks for uppercase letter
  9.   if it > 90 then
  10.     subtract 32 from it
  11.     put numtochar(it) into field "precedence"
  12.   end if
  13.   if field "Frequency" is empty then exit closeField
  14.   get field "Frequency"
  15.   set numberFormat to "0.000"
  16.   multiply it by 1
  17.   put it into field "Frequency"
  18.   put empty into band
  19.   put field "Frequency" into freq
  20.   if freq >= 1.8 and freq <= 2.0 then put 160 into band
  21.   if freq >= 3.5 and freq <= 3.75 then put 80 into band
  22.   if freq > 3.75 and freq <= 3.4 then put 75 into band
  23.   if freq >= 7.0 and freq <= 7.3 then put 40 into band
  24.   if freq >= 10.1 and freq <= 10.15 then put 30 into band
  25.   if freq >= 14.0 and freq <= 14.35 then put 20 into band
  26.   if freq >= 21.0 and freq <= 21.45 then put 15 into band
  27.   if freq >= 24.89 and freq <= 24.99 then put 12 into band
  28.   if freq >= 28.0 and freq <= 29.7 then put 10 into band
  29.   if freq >= 50.0 and freq <= 54.0 then put 6 into band
  30.   if freq >= 144.0 and freq <= 148.0 then put 2 into band
  31.   if band is empty then
  32.     beep
  33.     show message
  34.     put "Frequency out of amateur bands!" into message
  35.     exit closeField
  36.   end if
  37.   put band && "Meters" into field "band"
  38. end closeField
  39.  
  40.  
  41.  
  42.  
  43. -- part 9 (button)
  44. -- low flags: 00
  45. -- high flags: 0000
  46. -- rect: left=145 top=247 right=270 bottom=171
  47. -- title width / last selected line: 0
  48. -- icon id / first selected line: 1014 / 1014
  49. -- text alignment: 1
  50. -- font id: 0
  51. -- text size: 12
  52. -- style flags: 0
  53. -- line height: 16
  54. -- part name: Prev
  55. ----- HyperTalk script -----
  56. on mouseUp
  57.   go to prev card
  58. end mouseUp
  59.  
  60.  
  61.  
  62. -- part 8 (button)
  63. -- low flags: 00
  64. -- high flags: 0000
  65. -- rect: left=182 top=247 right=270 bottom=207
  66. -- title width / last selected line: 0
  67. -- icon id / first selected line: 1013 / 1013
  68. -- text alignment: 1
  69. -- font id: 0
  70. -- text size: 12
  71. -- style flags: 0
  72. -- line height: 16
  73. -- part name: Next
  74. ----- HyperTalk script -----
  75. on mouseUp
  76.   go to next card
  77. end mouseUp
  78.  
  79.  
  80.  
  81. -- part 46 (field)
  82. -- low flags: 00
  83. -- high flags: 4001
  84. -- rect: left=221 top=83 right=101 bottom=255
  85. -- title width / last selected line: 0
  86. -- icon id / first selected line: 0 / 0
  87. -- text alignment: 0
  88. -- font id: 3
  89. -- text size: 12
  90. -- style flags: 0
  91. -- line height: 16
  92. -- part name: hisNumber
  93.  
  94.  
  95. -- part 47 (field)
  96. -- low flags: 00
  97. -- high flags: 4001
  98. -- rect: left=298 top=83 right=101 bottom=332
  99. -- title width / last selected line: 0
  100. -- icon id / first selected line: 0 / 0
  101. -- text alignment: 0
  102. -- font id: 3
  103. -- text size: 12
  104. -- style flags: 0
  105. -- line height: 16
  106. -- part name: precedence
  107.  
  108.  
  109. -- part 19 (field)
  110. -- low flags: 00
  111. -- high flags: 4000
  112. -- rect: left=111 top=33 right=50 bottom=197
  113. -- title width / last selected line: 0
  114. -- icon id / first selected line: 0 / 0
  115. -- text alignment: 0
  116. -- font id: 128
  117. -- text size: 12
  118. -- style flags: 256
  119. -- line height: 16
  120. -- part name: station
  121.  
  122.  
  123. -- part 23 (field)
  124. -- low flags: 00
  125. -- high flags: 4001
  126. -- rect: left=67 top=105 right=123 bottom=115
  127. -- title width / last selected line: 0
  128. -- icon id / first selected line: 0 / 0
  129. -- text alignment: 0
  130. -- font id: 3
  131. -- text size: 12
  132. -- style flags: 0
  133. -- line height: 16
  134. -- part name: check
  135.  
  136.  
  137. -- part 22 (field)
  138. -- low flags: 00
  139. -- high flags: 4001
  140. -- rect: left=68 top=83 right=101 bottom=106
  141. -- title width / last selected line: 0
  142. -- icon id / first selected line: 0 / 0
  143. -- text alignment: 0
  144. -- font id: 3
  145. -- text size: 12
  146. -- style flags: 0
  147. -- line height: 16
  148. -- part name: QTH
  149.  
  150.  
  151. -- part 21 (field)
  152. -- low flags: 00
  153. -- high flags: 4000
  154. -- rect: left=263 top=33 right=51 bottom=326
  155. -- title width / last selected line: 0
  156. -- icon id / first selected line: 0 / 0
  157. -- text alignment: 0
  158. -- font id: 3
  159. -- text size: 12
  160. -- style flags: 0
  161. -- line height: 16
  162. -- part name: Frequency
  163.  
  164.  
  165. -- part 16 (button)
  166. -- low flags: 00
  167. -- high flags: 0000
  168. -- rect: left=109 top=247 right=274 bottom=139
  169. -- title width / last selected line: 0
  170. -- icon id / first selected line: 20689 / 20689
  171. -- text alignment: 1
  172. -- font id: 0
  173. -- text size: 12
  174. -- style flags: 0
  175. -- line height: 16
  176. -- part name: 
  177. ----- HyperTalk script -----
  178. on mouseUp
  179.   go home
  180. end mouseUp
  181.  
  182.  
  183.  
  184. -- part 41 (field)
  185. -- low flags: 00
  186. -- high flags: 0002
  187. -- rect: left=220 top=118 right=136 bottom=266
  188. -- title width / last selected line: 0
  189. -- icon id / first selected line: 0 / 0
  190. -- text alignment: 0
  191. -- font id: 3
  192. -- text size: 12
  193. -- style flags: 0
  194. -- line height: 16
  195. -- part name: mode
  196.  
  197.  
  198. -- part 27 (field)
  199. -- low flags: 00
  200. -- high flags: 4007
  201. -- rect: left=300 top=139 right=268 bottom=481
  202. -- title width / last selected line: 0
  203. -- icon id / first selected line: 0 / 0
  204. -- text alignment: 0
  205. -- font id: 3
  206. -- text size: 12
  207. -- style flags: 0
  208. -- line height: 16
  209. -- part name: comments
  210.  
  211.  
  212. -- part 18 (field)
  213. -- low flags: 00
  214. -- high flags: 4000
  215. -- rect: left=214 top=59 right=77 bottom=293
  216. -- title width / last selected line: 0
  217. -- icon id / first selected line: 0 / 0
  218. -- text alignment: 0
  219. -- font id: 3
  220. -- text size: 12
  221. -- style flags: 0
  222. -- line height: 16
  223. -- part name: Time
  224.  
  225.  
  226. -- part 17 (field)
  227. -- low flags: 00
  228. -- high flags: 4000
  229. -- rect: left=49 top=59 right=78 bottom=173
  230. -- title width / last selected line: 0
  231. -- icon id / first selected line: 0 / 0
  232. -- text alignment: 0
  233. -- font id: 128
  234. -- text size: 12
  235. -- style flags: 0
  236. -- line height: 16
  237. -- part name: Zulu Date
  238.  
  239.  
  240. -- part 29 (button)
  241. -- low flags: 00
  242. -- high flags: 8003
  243. -- rect: left=318 top=293 right=315 bottom=418
  244. -- title width / last selected line: 0
  245. -- icon id / first selected line: 0 / 0
  246. -- text alignment: 1
  247. -- font id: 0
  248. -- text size: 12
  249. -- style flags: 0
  250. -- line height: 16
  251. -- part name: Import old log
  252. ----- HyperTalk script -----
  253. on mouseUp
  254.   ask "Import text from which file?"
  255.   if it is empty then exit mouseUp
  256.   put it into fileName
  257.   open file fileName
  258.   doMenu "New Card"
  259.   repeat
  260.     read from file fileName until return -- get first record
  261.     if it is empty then
  262.       doMenu "Delete Card"
  263.       close file fileName
  264.       exit mouseUp
  265.     end if
  266.     put it into data
  267.     repeat with i = 1 to the number of fields
  268.       if first word of data is empty or first word of data is return
  269.       then exit repeat -- stop
  270.       put offset(tab,data) into num --gets field field (until tab)
  271.       if num is 0 then -- checks for last field of record
  272.         put data into field i -- writes last field
  273.         exit repeat
  274.       end if
  275.       put char 1 to (num - 1) of data into field i -- writes first field
  276.       delete char 1 to num of data -- gets rid of field
  277.     end repeat
  278.     doMenu "New Card"
  279.   end repeat
  280. end mouseUp
  281.  
  282.  
  283.  
  284. -- part 31 (field)
  285. -- low flags: 00
  286. -- high flags: 0000
  287. -- rect: left=383 top=53 right=72 bottom=463
  288. -- title width / last selected line: 0
  289. -- icon id / first selected line: 0 / 0
  290. -- text alignment: 1
  291. -- font id: 0
  292. -- text size: 12
  293. -- style flags: 0
  294. -- line height: 16
  295. -- part name: Local Time
  296.  
  297.  
  298. -- part 34 (button)
  299. -- low flags: 00
  300. -- high flags: 8003
  301. -- rect: left=21 top=146 right=168 bottom=98
  302. -- title width / last selected line: 0
  303. -- icon id / first selected line: 0 / 0
  304. -- text alignment: 1
  305. -- font id: 0
  306. -- text size: 12
  307. -- style flags: 0
  308. -- line height: 16
  309. -- part name: New Entry
  310. ----- HyperTalk script -----
  311. on mouseUp
  312.   get the value of field "myNumber"
  313.   add 1 to it
  314.   put it into nr
  315.   go to last card
  316.   doMenu "New Card"
  317.   put nr into field "myNumber"
  318.   global timezone
  319.   global zfactor
  320.   get the time
  321.   put it && timezone into field "Local Time"
  322.   convert it to secs
  323.   add zfactor to it
  324.   convert it to time
  325.   put it && "Z" into field "Zulu Time"
  326.   tabKey
  327. end mouseUp
  328.  
  329.  
  330.  
  331. -- part 35 (button)
  332. -- low flags: 00
  333. -- high flags: 0000
  334. -- rect: left=26 top=248 right=300 bottom=95
  335. -- title width / last selected line: 0
  336. -- icon id / first selected line: 1012 / 1012
  337. -- text alignment: 1
  338. -- font id: 0
  339. -- text size: 12
  340. -- style flags: 0
  341. -- line height: 16
  342. -- part name: Return
  343. ----- HyperTalk script -----
  344. on mouseUp
  345.   visual effect iris close
  346.   pop card
  347. end mouseUp
  348.  
  349.  
  350.  
  351. -- part 36 (field)
  352. -- low flags: 00
  353. -- high flags: 0000
  354. -- rect: left=385 top=86 right=104 bottom=460
  355. -- title width / last selected line: 0
  356. -- icon id / first selected line: 0 / 0
  357. -- text alignment: 1
  358. -- font id: 0
  359. -- text size: 12
  360. -- style flags: 0
  361. -- line height: 16
  362. -- part name: Zulu Time
  363.  
  364.  
  365. -- part 38 (button)
  366. -- low flags: 00
  367. -- high flags: 8003
  368. -- rect: left=31 top=207 right=229 bottom=81
  369. -- title width / last selected line: 0
  370. -- icon id / first selected line: 0 / 0
  371. -- text alignment: 1
  372. -- font id: 0
  373. -- text size: 12
  374. -- style flags: 0
  375. -- line height: 16
  376. -- part name: Dupe
  377. ----- HyperTalk script -----
  378. on mouseUp
  379.   show message
  380.   global duper
  381.   put empty into duper
  382.   repeat for the number of cards - 1
  383.     if duper is empty then go to first card of background "QSO"
  384.     else go to card duper + 1
  385.     put field "Station" into callchecker
  386.     put id of this card into cardchecker
  387.     put number of this card into duper
  388.     if duper is 1 then exit repeat
  389.     put field "band" into bander
  390.     find callchecker
  391.     find callchecker
  392.     put id of this card into dupechecker
  393.     put field "band" into bandchecker
  394.     if cardchecker is dupechecker and bander is bandchecker then
  395.       put "OK" && duper into message
  396.     else
  397.       beep
  398.       put "Duplicate, card" && duper into field "dupe"
  399.       go to card duper
  400.     end if
  401.   end repeat
  402. end mouseUp
  403.  
  404.  
  405.  
  406. -- part 39 (button)
  407. -- low flags: 00
  408. -- high flags: 8003
  409. -- rect: left=80 top=175 right=198 bottom=126
  410. -- title width / last selected line: 0
  411. -- icon id / first selected line: 0 / 0
  412. -- text alignment: 1
  413. -- font id: 0
  414. -- text size: 12
  415. -- style flags: 0
  416. -- line height: 16
  417. -- part name: Log
  418. ----- HyperTalk script -----
  419. on mouseUp
  420.   global timezone
  421.   global zfactor
  422.   get the time
  423.   convert it to secs
  424.   add zfactor to it
  425.   convert it to time
  426.   put it && "Z" into field "Time"
  427.   convert it to secs
  428.   convert it to date
  429.   put it && "(UTC)" into field "Zulu Date"
  430.   put field frequency into freq
  431.   put empty into band
  432.   if freq is empty then exit mouseUp
  433.   if freq >= 1.8 and freq <= 2.0 then put 160 into band
  434.   if freq >= 3.5 and freq <= 3.75 then put 80 into band
  435.   if freq >= 3.751 and freq <= 4.0 then put 75 into band
  436.   if freq >= 7.0 and freq <= 7.3 then put 40 into band
  437.   if freq >= 10.1 and freq <= 10.15 then put 30 into band
  438.   if freq >= 14.0 and freq <= 14.35 then put 20 into band
  439.   if freq >= 21.1 and freq <= 21.45 then put 15 into band
  440.   if freq >= 24.89 and freq <= 24.99 then put 12 into band
  441.   if freq >= 28.0 and freq <= 29.7 then put 10 into band
  442.   if freq >= 50.0 and freq <= 54.0 then put 6 into band
  443.   if freq >= 144.0 and freq <= 148.0 then put 2 into band
  444.   if band is empty then
  445.     beep
  446.     put "Frequency out of bounds!" into message
  447.     exit mouseUp
  448.   end if
  449.  
  450.   put band && "Meters" into field "band"
  451. end mouseUp
  452.  
  453.  
  454.  
  455. -- part 40 (field)
  456. -- low flags: 00
  457. -- high flags: 0000
  458. -- rect: left=79 top=210 right=229 bottom=210
  459. -- title width / last selected line: 0
  460. -- icon id / first selected line: 0 / 0
  461. -- text alignment: 0
  462. -- font id: 3
  463. -- text size: 12
  464. -- style flags: 0
  465. -- line height: 16
  466. -- part name: dupe
  467.  
  468.  
  469. -- part 42 (field)
  470. -- low flags: 00
  471. -- high flags: 0002
  472. -- rect: left=198 top=140 right=158 bottom=279
  473. -- title width / last selected line: 0
  474. -- icon id / first selected line: 0 / 0
  475. -- text alignment: 0
  476. -- font id: 3
  477. -- text size: 12
  478. -- style flags: 0
  479. -- line height: 16
  480. -- part name: band
  481.  
  482.  
  483. -- part 43 (button)
  484. -- low flags: 00
  485. -- high flags: 8003
  486. -- rect: left=220 top=248 right=268 bottom=272
  487. -- title width / last selected line: 0
  488. -- icon id / first selected line: 0 / 0
  489. -- text alignment: 1
  490. -- font id: 0
  491. -- text size: 12
  492. -- style flags: 0
  493. -- line height: 16
  494. -- part name: Stars
  495. ----- HyperTalk script -----
  496. on mouseUp
  497.   doMenu "Stars1.6"
  498. end mouseUp
  499.  
  500.  
  501.  
  502. -- part 44 (button)
  503. -- low flags: 00
  504. -- high flags: 8003
  505. -- rect: left=17 top=176 right=198 bottom=75
  506. -- title width / last selected line: 0
  507. -- icon id / first selected line: 0 / 0
  508. -- text alignment: 1
  509. -- font id: 0
  510. -- text size: 12
  511. -- style flags: 0
  512. -- line height: 16
  513. -- part name: Start
  514. ----- HyperTalk script -----
  515. on mouseUp
  516.   global timezone
  517.   global zfactor
  518.   get the time
  519.   put it && timezone into field "Local Time"
  520.   convert it to secs
  521.   add zfactor to it
  522.   convert it to time
  523.   put it && "Z" into field "Zulu Time"
  524. end mouseUp
  525.  
  526.  
  527.  
  528. -- part 45 (field)
  529. -- low flags: 00
  530. -- high flags: 4002
  531. -- rect: left=148 top=83 right=101 bottom=180
  532. -- title width / last selected line: 0
  533. -- icon id / first selected line: 0 / 0
  534. -- text alignment: 0
  535. -- font id: 3
  536. -- text size: 12
  537. -- style flags: 0
  538. -- line height: 16
  539. -- part name: myNumber
  540.